package org.dairy.farms.core;

/**
 * Created by IntelliJ IDEA.
 * User: gduggira
 * Date: Jun 13, 2011
 * Time: 1:18:48 PM
 */
public class NandanaThreadLocal {
    public static final ThreadLocal<UserSession> userThreadLocal = new ThreadLocal<UserSession>();

    public static void set(UserSession user) {
        userThreadLocal.set(user);
    }

    public static void unset() {
        userThreadLocal.remove();
    }

    public static UserSession get() {
        return userThreadLocal.get();
    }
}
